package haois.module.tasks.service;

import org.quartz.Job;
import org.quartz.JobExecutionContext;
import org.quartz.JobExecutionException;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.stereotype.Component;

/**
 * Created by RuiHaoZ on 2018/4/29 12:45
 * https://blog.csdn.net/liuchuanhong1/article/details/60873295
 */
@Component // 此注解必加
public class SayHelloJob extends BaseJob {
    private static final Logger logger = LoggerFactory.getLogger(SayHelloJob.class);

    @Override
    public void execute(JobExecutionContext jobExecutionContext) throws JobExecutionException {
        logger.info("Hello execute, HelloJob");
    }
    public void sayHello(){
        logger.info("SyeHello");
    }
}
